import request from '@/utils/request'

// 获取套餐
export function getSetMeal(data) {
  return request({
    url: '/api/goodsCategory/listPackageCategory',
    method: 'get',
    params: data
  })
}

// 添加套餐
export function addSetMeal(data) {
  return request({
    url: '/api/goodsCategory/savePackageCategory',
    method: 'post',
    data: data
  })
}

// 删除套餐
export function deleteSetMeal(id) {
  return request({
    url: '/api/goodsCategory/deletePackageCategory/' + id,
    method: 'delete'
  })
}

// 获取菜品
export function getDishes(data) {
  return request({
    url: '/api/goodsCategory/listDishCategory',
    method: 'get',
    data: data
  })
}

// 添加菜品
export function addDishes(data) {
  return request({
    url: '/api/goodsCategory/saveDishCategory',
    method: 'post',
    data: data
  })
}

// 删除菜品
export function deleteDishes(id) {
  return request({
    url: '/api/goodsCategory/deleteDishCategory/' + id,
    method: 'delete'
  })
}

// 获取烹饪
export function getCooking(data) {
  return request({
    url: '/api/goodsCategory/listCookMethod',
    method: 'get',
    data: data
  })
}

// 添加烹饪
export function addCooking(data) {
  return request({
    url: '/api/goodsCategory/saveCookMethod',
    method: 'post',
    data: data
  })
}

// 删除烹饪
export function deleteCooking(id) {
  return request({
    url: '/api/goodsCategory/deleteCookMethod/' + id,
    method: 'delete'
  })
}

// 获取原料
export function getMate(data) {
  return request({
    url: '/api/goodsCategory/listMaterialAmount',
    method: 'get',
    params: data
  })
}

// 添加原料
export function addMate(data) {
  return request({
    url: '/api/goodsCategory/saveMaterialAmount',
    method: 'post',
    data: data
  })
}

// 删除原料
export function deleteMate(id) {
  return request({
    url: '/api/goodsCategory/deleteMaterialAmount/' + id,
    method: 'delete'
  })
}
